package cn.stylefeng.guns.modular.business.custom.enums;

/**
 * @Description:
 * @Author jzy
 * @Date 2019/12/9 0009
 **/
public enum OrderStatusEnum {

    HAD_CANCEL(-2, "已作废"),
    HAD_WITHDRAWN(-1, "已撤销"),
    //    WAIT_FOR_CHECK_ORDER(0, "待审核"),
    NEW_ORDER(1, "待指派"),//待提车
    WAIT_ASSIGN_DRIVER(105, "待指派司机"),//已删除
    WAIT_PICK(2, "待验车"),
    PICK_SIGNED(205, "待入库"),//已删除

    NOT_DEPART_ORDER(3, "待发运"),
    TRANSFERRING_SIGN(305, "中转签收"),
    HAS_DEPART_ORDER(4, "运输中"),
    FINISHED_TRANSPORT(5, "待指派送车"),
    WAIT_ASSIGN_TAKE_DRIVER(505, "待指派司机"),
    WAIT_TAKE(6, "待交付"),
    CUSTOMER_HAS_SIGN(7, "已完成");

    public int status;

    public String desc;

    OrderStatusEnum(int status, String desc) {
        this.status = status;
        this.desc = desc;
    }

    public static String getValue(Integer type) {
        if (type == null) {
            return "";
        }
        OrderStatusEnum[] pts = OrderStatusEnum.values();
        for (OrderStatusEnum pt : pts) {
            if (type == pt.status) {
                return pt.desc;
            }
        }
        return "";
    }
}
